package meihua.mylibrary.basebean;

/**
 * Name: LGZ
 * Time: 2017/5/4.
 * Dec:
 */

public class BaseResult {


    public static final int SUCCESS = 0;
    public static final int FAILED = -1;

    Integer code;
    String msg;

    public BaseResult() {
        super();
//        setCode(SUCCESS);
    }

//    public BaseResult(String errorInfo) {
//        setErrorInfo(errorInfo);
//    }

    public final Integer getCode() {
        return code;
    }

    public final BaseResult setCode(Integer code) {
        this.code = code;
        return this;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

//    protected final BaseResult setErrorInfo(String msg) {
//        this.code = FAILED;
//        this.msg = msg;
//        return this;
//    }
//
//    public final boolean failed() {
//        return code == FAILED;
//    }

}
